package co.yixiang.modules.activity.vo;


import co.yixiang.modules.user.vo.YxUserQueryVo;
import lombok.Data;

import java.io.Serializable;

/**
 * @ClassName BargainVo
 * @Author hupeng <610796224@qq.com>
 * @Date 2019/12/21
 **/
@Data
public class BargainVo implements Serializable {
    private YxStoreBargainQueryVo bargain;
    private YxUserQueryVo userInfo;
    private Integer bargainSumCount;//砍价支付成功订单数量

    BargainVo(YxStoreBargainQueryVo bargain, YxUserQueryVo userInfo, Integer bargainSumCount) {
        this.bargain = bargain;
        this.userInfo = userInfo;
        this.bargainSumCount = bargainSumCount;
    }

    public static BargainVoBuilder builder() {
        return new BargainVoBuilder();
    }

    public static class BargainVoBuilder {
        private YxStoreBargainQueryVo bargain;
        private YxUserQueryVo userInfo;
        private Integer bargainSumCount;

        BargainVoBuilder() {
        }

        public BargainVoBuilder bargain(YxStoreBargainQueryVo bargain) {
            this.bargain = bargain;
            return this;
        }

        public BargainVoBuilder userInfo(YxUserQueryVo userInfo) {
            this.userInfo = userInfo;
            return this;
        }

        public BargainVoBuilder bargainSumCount(Integer bargainSumCount) {
            this.bargainSumCount = bargainSumCount;
            return this;
        }

        public BargainVo build() {
            return new BargainVo(bargain, userInfo, bargainSumCount);
        }

        public String toString() {
            return "BargainVo.BargainVoBuilder(bargain=" + this.bargain + ", userInfo=" + this.userInfo + ", bargainSumCount=" + this.bargainSumCount + ")";
        }
    }
}
